package com.example.demo.controller;

import com.example.demo.entity.User;
import org.springframework.web.bind.annotation.CrossOrigin;
import org.springframework.web.bind.annotation.RequestMethod;

import java.util.List;
@CrossOrigin(origins = "*", methods = {RequestMethod.GET, RequestMethod.POST})
/**
 * @apiNote 用于实现输出函数的封装
 * @author 钟顺浩
 * @email 2918185121@qq.com
 * @since 1.0.0
 */
public class BaseController {

    /**
     * @apiNote 用于实现用输出字符串
     * @author 钟顺浩
     * @param s 字符串
     * @email 2918185121@qq.com
     * @since 1.0.0
     */
    protected void print(String s){
        System.out.println(s);
    }


    /**
     * @apiNote 用于实现用输出字符串
     * @author 钟顺浩
     * @param list 对象集合
     * @email 2918185121@qq.com
     * @since 1.0.0
     */
    protected void printList(List<User> list){
        System.out.println(list);
    }


}
